feat: support iOS source-map uploads#871
Open
ablaszkiewicz wants to merge 14 commits into
Open
Conversation
🧙 Wizard CIRun the Wizard CI and test your changes against wizard-workbench example apps by replying with a GitHub comment using one of the following commands: Test all apps:
Test all apps in a directory:
Test an individual app:
Show more apps
Results will be posted here when complete. |
This was referenced Jul 11, 2026
Native iOS never loads a .env at build time, so the personal API key the dSYM upload needs was being written to a file Xcode ignores. Route it through a gitignored xcconfig instead: - set_env_values writes Xcode `KEY = VALUE` style (and gitignores the file) when the target path ends in .xcconfig, reusing the existing secret-vault resolution so the key never reaches the agent. - The source-maps prompt branches on the iOS variant: secret to PostHog.xcconfig, non-secret project id / host as export lines in the dSYM-upload Run Script build phase. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
POSTHOG_CLI_HOST was interpolated from ctx.host — the SDK/ingestion host (us.i.posthog.com) — so generated build phases and .env files pointed posthog-cli at a host that does not serve the upload API. Use the uiHost the prompt already derives (us.posthog.com), in both the iOS xcconfig branch and the dotenv branch, and tell the agent explicitly never to copy the *.i.posthog.com host out of SDK setup code. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The generic test-done template bakes CLI build/run commands, so iOS runs mixed xcodebuild with Xcode GUI steps and imported debugger-detach / relaunch steps from the crash-testing docs — the test captures an exception event, not a crash. iOS now gets a fixed three-step Xcode script: set Run configuration to Release, run, tap, check. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Two live runs in a row generated the upload phase without the prefix —
symbols uploaded, source never did ('frame resolved but no source
context'). The skill snippet alone doesn't hold; make it a wizard-side
MUST tied to the symptom.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
All three POSTHOG_CLI_* values go in the gitignored xcconfig — the host written as https:/$()/… so // doesn't start an xcconfig comment. One set_env_values call replaces the secret-write + phase-exports split, and the prompt sheds the fallback/host-warning prose the skill now owns. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Agents dropped the command-line prefix in three consecutive runs. Build settings export to Run Script environments, so the flag lives in the xcconfig with the other values — the phase invocation has nothing left to drop. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The SDK's upload-symbols.sh now accepts POSTHOG_DOTENV_FILE and forwards it to posthog-cli --dotenv-file, so iOS joins the standard gitignored .env flow. Drops the xcconfig assignment style from set_env_values and the iOS-specific credential branch from the source-maps prompt; the Xcode-based test instructions remain. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…oudly An agent running in a project nested inside a larger git repo prefixed set_env_values' filePath with the project's repo-relative location, and the tool silently mkdir'd a duplicate nested tree for the .env. Refuse to create missing parent directories (with an instructive error), spell out the resolution base in both tools' filePath descriptions, and stop calling the project directory 'the repo root' in the source-maps prompt. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The STEP 8 test-done wizard_ask hardcoded a CLI build/run template plus an isIos-gated Xcode variant. The skill's "Identify the build and run commands" and "Test the local setup" steps already carry the per-platform flow (Xcode Release run, gradle, react-native CLI), so the prompt now composes steps 1-2 from STEP 6's skill-resolved flow and keeps only the invariants: numbered copy-pasteable steps, the Error Tracking check, the Continue-and-revert contract. Enabling Android or React Native later is a context-mill skill change, not a prompt edit. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Reverts the skill-delegation rewrite (605f602) — the pinned template text stays exactly as before — and moves the inline isIos ternary into TEST_DONE_PROMPT_OVERRIDES, a Partial<Record<SkillVariant, ...>> keyed by variant. Supporting android or react-native later means adding an entry; the prompt body no longer branches on platform. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
gewenyu99
reviewed
Jul 15, 2026
| * platform (android, react-native, …) means adding an entry — the prompt | ||
| * body stays untouched. | ||
| */ | ||
| const TEST_DONE_PROMPT_OVERRIDES: Partial< |
Collaborator
There was a problem hiding this comment.
Should these stay here or as "variants" in the context mill?
I'm a little worried that this shape is quickly turning from exceptions to shipping context in wizard instead of skills
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

This PR adds support for iOS source maps. Tested both CocoaPods and SPM (Swift Package Manager) approaches. I assume that iOS devs are using xcode so this is xcode focused. As a result of this wizard run you literally press "play" in xcode and EVERYTHING works!
Also experienced a bug where agent tried creating some crazy directory tree and put
.envfile in it. Hardened that partCompanion PRs